<template>
  <div class="home-wrap">
    <el-carousel :interval="4000" type="card" height="400px">
      <el-carousel-item v-for="item in imageList" :key="item">
        <el-image
          style="width: 100%; height: 100%"
          :src="item"
          fit="contain"
        ></el-image>
      </el-carousel-item>
    </el-carousel>
  </div>
</template>

<script>
import img1 from "@/assets/1.jpg";
import img2 from "@/assets/2.jpg";
import img3 from "@/assets/3.jpg";
import img4 from "@/assets/4.jpg";
import img5 from "@/assets/5.jpg";
import img6 from "@/assets/6.jpg";
export default {
  name: "home-page",
  data() {
    return {
      imageList: [img1, img2, img3, img4, img5, img6],
    };
  },
};
</script>

<style scoped>
.home-wrap {
  width: 100%;
  height: 100%;
}
.el-carousel__item h3 {
  color: #475669;
  font-size: 14px;
  opacity: 0.75;
  line-height: 200px;
  margin: 0;
}

.el-carousel__item:nth-child(2n) {
  background-color: #99a9bf;
}

.el-carousel__item:nth-child(2n + 1) {
  background-color: #d3dce6;
}
</style>
